class User { ... static constraints = { login shared: "myShared" } }
grails.gorm.default.constraints = { '*'(nullable: true, size: 1..20) myShared(nullable: false, blank: false) }